local huzhang = fk.CreateSkill{
    name = "ym_water__huzhang",
}
Fk:loadTranslationTable{
    ["ym_water__huzhang"] = "互仗",
    [":ym_water__huzhang"] = "出牌阶段，你可以视为使用一张【树上开花】；若弃置牌名字数和与上次相等，以此使用的【树上开花】弃牌上下限+1；否则重置此技能并令之本回合失效。",
    ["#ym_water__huzhang"] = "互仗：视为使用一张【树上开花】",
    ["#ym_water__huzhang_bogus_flower-discard"] = "树上开花：弃置%arg至%arg2张牌，摸等量的牌，若弃置了装备牌则多摸一张",
    ["@ym_water__huzhang"] = "互仗",
    ["ym_water__huzhang_bogus_flower_skill"] = "树上开花",

    ["$ym_water__huzhang1"] = "楼上北风斜卷席，湖中西日倒衔山。",
    ["$ym_water__huzhang2"] = "鸟啼花落人何在？竹死桐枯凤不来。",
}
huzhang:addEffect("viewas",{
    prompt = "#ym_water__huzhang",
    pattern = "bogus_flower",
    card_num = 0,
    card_filter = Util.FalseFunc,
    view_as = function (self, player, cards)
        local card = Fk:cloneCard("bogus_flower")
        card.skillName = huzhang.name
        return card
    end,
    enabled_at_play = Util.TrueFunc,
    enabled_at_response = Util.FalseFunc,
})
huzhang:addEffect(fk.PreCardEffect,{
    can_refresh = function (self, event, target, player, data)
        return target == player and data and data.card.trueName == "bogus_flower" and data.card.skillName == huzhang.name
    end,
    on_refresh = function(self, event, target, player, data)
        local card = data.card:clone()
        local c = table.simpleClone(data.card)
        for k, v in pairs(c) do
            card[k] = v
        end
        card.skill = Fk.skills["ym_water__huzhang_bogus_flower_skill"]
        data.card = card
    end,
})

return huzhang
